/**
 * @Author: zhoujie
 * @Date: 2019/08/24
 * @Last Modified by:   zhoujie
 * @Last Modified time: 2019/08/24 15:45:00
 */

const RouteView = () => import('@/layout/RouteView');
// 异步路由组件加载
const AsyncComponent = __name__ => () => import(`@/pages/${__name__}`);

/** 衍生业务 菜单路由 */
const menuRoutes = [
  /** 衍生业务 S */
  {
    path: '/derived',
    meta: { title: '衍生业务', icon: 'el-icon-s-cooperation' },
    redirect: '/derived',
    component: RouteView,
    children: [
      {
        path: '/derived/insurance',
        meta: { title: '保险业务' },
        redirect: '/derived/insurance',
        component: RouteView,
        children: [
          {
            path: '/derived/insurance/insurancePolicy',
            meta: { title: '保险投保单', keepAlive: true },
            component: AsyncComponent('derived/insurance/insurancePolicy')
          }
        ]
      }
    ]
  }
  /** 衍生业务 E */
];

export default menuRoutes;
